package com.zb.client;

import com.zb.dto.SkuDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

@FeignClient(value = "goods-server")
public interface SkuFeignClient {
    @GetMapping("/tb-sku-model/info")
    SkuDTO info(@RequestParam("id")String id);

    @PostMapping("/tb-sku-model/update-num")
    public Boolean update(@RequestParam("id")String id,@RequestParam("num")Integer num);


    @GetMapping("/tb-sku-model/page")
    public List<SkuDTO> page(@RequestParam("index")Integer index,
                             @RequestParam("size")Integer size);


    @GetMapping("/tb-sku-model/item")
    public Map<String, Object> item(@RequestParam("skuId") String skuId);
}


